package double

import "sync"

type instance struct{}

var (
	aInstance *instance
	lock      sync.Mutex
)

func GetDoubleLockInstance() *instance {
	if aInstance == nil {
		lock.Lock()
		defer lock.Unlock()
		if aInstance == nil {
			aInstance = &instance{}
		}
	}
	return aInstance
}
